package com.haiyi.software.entity;

@Deprecated
public class EntityMessage {

	public String getBody() {
		if (body != null)
			return body;
		else
			return "";
	}

	public void setBody(String body) {
		this.body = body;
	}

	public String getName() {
		if (name != null)
			return name;
		else
			return "";
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getUhead() {
		if (uhead != null)
			return uhead;
		else
			return "";
	}

	public void setUhead(String uhead) {
		this.uhead = uhead;
	}

	public String getGif() {
		if (gif != null)
			return gif;
		else
			return "";
	}

	public void setGif(String gif) {
		this.gif = gif;
	}

	public String getLocal_voice_path() {
		if (local_voice_path != null)
			return local_voice_path;
		else
			return "";
	}

	public void setLocal_voice_path(String local_voice_path) {
		this.local_voice_path = local_voice_path;
	}

	public String getLocal_image_path() {
		if (local_image_path != null)
			return local_image_path;
		else
			return "";
	}

	public void setLocal_image_path(String local_image_path) {
		this.local_image_path = local_image_path;
	}

	public String getImage() {
		if (image != null)
			return image;
		else
			return "";
	}

	public void setImage(String image) {
		this.image = image;
	}

	public String getVoice() {
		if (voice != null)
			return voice;
		else
			return "";
	}

	public void setVoice(String voice) {
		this.voice = voice;
	}

	private String body;

	private String name;

	private String uhead;

	private String gif;

	private String local_voice_path;

	private String local_image_path;

	private String image;

	private String voice;

	private int messageCategory;

	private String youUID;

	private String allMessage;

	private String theMessageID;

	public String getTheMessageID() {
		return theMessageID;
	}

	public void setTheMessageID(String theMessageID) {
		this.theMessageID = theMessageID;
	}

	public String getAllMessage() {
		return allMessage;
	}

	public void setAllMessage(String allMessage) {
		this.allMessage = allMessage;
	}

	public final static int MESSAGECATEGORY_VOICE = 1;
	public final static int MESSAGECATEGORY_TEXT = 2;
	public final static int MESSAGECATEGORY_VIDEO = 3;
	public final static int MESSAGECATEGORY_GIF = 4;

	/**
	 * 获取消息的类别，语音：1，文字：2，视频：3，GIF：4，等
	 * 
	 * @return
	 */
	public int getMessageCategory() {

		if (gif != null && gif.trim().length() > 0) {
			return MESSAGECATEGORY_GIF;
		} else if (voice != null && voice.trim().length() > 0) {
			return MESSAGECATEGORY_VOICE;
		} else {
			return MESSAGECATEGORY_TEXT;
		}
	}

	public String getYouUID() {
		// TODO 自动生成的方法存根
		return youUID;
	}

	public void setYouUID(String youUID) {
		this.youUID = youUID;
	}
}
